/******************************************************************************
* ++
* Author: BaoTD1
* Module Name : CBoardCell.h
*
* Description : Declares the CBoard Cell Windows Form
*
*
* Mod. History :	03/Dec/2012		 - BaoTD1
*                             File first created
*                             CR# PROJECT
*
*
* --
******************************************************************************/
#pragma once
#ifndef CBoardCell_H
#define CBoardCell_H
#include "stdafx.h"
#include "common_def.h"
using namespace Gdiplus;

//////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Structure Name:	TAG_COLOR_TABLE_ENTRY
// Description:		To hold the colors and their names
// Explanation:		
// Attention:		
// End:
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
typedef struct ColorTableEntry_t
{
	COLORREF	crColour;
} COLOR_TABLE_ENTRY_t;

class CBoardCell : public CStatic
{
protected:
	int			m_nCellID;		// Cell ID
	Color		m_CellColor;	// Cell Color
	//int		m_nWidth;		// Cell width
	//int		m_nHeight;		// Cell height
	CString		m_szCellImage;	// CellImage
	BOOL		m_bClicked;		// Cell is clicked
	CWnd*		m_pParentWnd;	// Parent Windows
	RECT		m_ClientRect;	// Client rect of Board Cell

public:
	CBoardCell(void);
	CBoardCell(int nCellID/*, Color CellColor, int nWidth, int nHeight*/);
	~CBoardCell(void);

	int		getCellID();
	/*int	getWidth();
	int		getHeight();*/
	RECT	getRect();
	void	setRect(RECT*);
	void	setCellColor(Color);
	void	setCellImage(CString);

	//Draw Cell
	void	DrawCell( Graphics* graphic, RECT rect );

	virtual BOOL CreateBoardCell( const RECT& rect, CWnd* pParentWnd )	= 0;

	DECLARE_MESSAGE_MAP()
};

#endif
